<?php
header("content-type:text/html;charset=utf8");
$id = isset($_GET['id'])?$_GET['id']:"";
$pdo = new PDO("mysql:host=127.0.0.1;dbname=11-9;charset=utf8;",'root','root');
$sql = "delete from excel where id = $id";
$res = $pdo->exec($sql);
if($res)
{
    echo "<script>alert('删除成功');location.href='show.php'</script>";

}
else{
    echo "<script>alert('删除失败');location.href='show.php'</script>";
}
?>